/*
 * AttrImpl.cpp
 *
 *  Created on: Apr 19, 2009
 *      Author: wrice
 */

#include "DOMCoreImp.h"
namespace DOMCoreImp {


AttrImp::AttrImp(DOMString nodeName, DocumentImp * ownerDocument)
: NodeImp(nodeName, ownerDocument)
{
}

unsigned short AttrImp::getNodeType() { return Node::ATTRIBUTE_NODE; }


DOMString AttrImp::getName() { return getNodeName(); }

DOMString AttrImp::getValue() {
	return getNodeValue();
}

void AttrImp::setValue(DOMString value) throw(DOMExceptionPtr) {
	setNodeValue(value);
}

Node * AttrImp::insertBefore( Node * newChild, Node * refChild ) throw(DOMExceptionPtr) {
	throw DOMExceptionPtr(new DOMExceptionImp(DOMException::NO_MODIFICATION_ALLOWED_ERR));
}

Node * AttrImp::replaceChild( Node * newChild, Node * oldChild ) throw (DOMExceptionPtr) {
	throw DOMExceptionPtr(new DOMExceptionImp(DOMException::NO_MODIFICATION_ALLOWED_ERR));
}

Node * AttrImp::removeChild( Node * oldChild) throw(DOMExceptionPtr) {
	throw DOMExceptionPtr(new DOMExceptionImp(DOMException::NO_MODIFICATION_ALLOWED_ERR));
}

Node * AttrImp::appendChild( Node * newChild) throw(DOMExceptionPtr) {
	throw DOMExceptionPtr(new DOMExceptionImp(DOMException::NO_MODIFICATION_ALLOWED_ERR));
}

}
